<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改代理商推送配置')" />
    <th:block th:include="include :: datetimepicker-css" />
    </head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-agentAysinfo-edit" th:object="${agentAysinfo}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">
                <label class="col-sm-3 control-label">代理推送地址：</label>
                <div class="col-sm-8">
                    <input name="agentUrl" th:field="*{agentUrl}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">推送类型：</label>
                <div class="col-sm-8">
                    <select name="asyType" class="form-control m-b" th:field="*{asyType}">
                        <option value="0">商户</option>
                        <option value="1">交易</option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">推送状态：</label>
                <div class="col-sm-8">
                    <select name="status" class="form-control m-b" th:field="*{status}">
                        <option value="0">推送</option>
                        <option value="1">关闭</option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">代理编号：</label>
                <div class="col-sm-8">
                    <input name="agentNum" th:field="*{agentNum}" class="form-control" type="text">
                </div>
            </div>

            <div class="form-group">
                <label class="col-sm-3 control-label">代理公钥：</label>
                <div class="col-sm-8">
                    <input name="agentPub" th:field="*{agentPub}" class="form-control" type="text">
                </div>
            </div>

            <div class="form-group">
                <label class="col-sm-3 control-label">系统私钥：</label>
                <div class="col-sm-8">
                    <input name="sysPri" th:field="*{sysPri}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">系统公钥：</label>
                <div class="col-sm-8">
                    <input name="sysPub" th:field="*{sysPub}" class="form-control" type="text">
                </div>
            </div>

        </form>
    </div>
    <th:block th:include="include :: footer" />
    <th:block th:include="include :: datetimepicker-js" />
    <script th:inline="javascript">
        var prefix = ctx + "agentAysinfo/agentAysinfo";
        $("#form-agentAysinfo-edit").validate({
            focusCleanup: true
        });

        $("input[name='date']").datetimepicker({
            format: "yyyy-mm-dd",
            minView: "month",
            autoclose: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-agentAysinfo-edit').serialize());
            }
        }
    </script>
</body>
</html>